import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
import 'package:provider_demo/providers/app_providers.dart';
import 'app_widget.dart';
import 'models/counter_model.dart';

// main.dart 修正方案
void main() {
  runApp(
    MultiProvider(
      providers:appProviders,
      // [
      //   ChangeNotifierProvider(create: (_) => CounterModel()), // 确保这里已注册
      // ],
      child: const MyApp(),
    ),
  );
}